package jcataloger.resources;

import java.util.MissingResourceException;
import java.util.ResourceBundle;

/**
 * Project uses some parameters like key shortcuts. They are kept in a resource file and <br>
 * read by this class.
 * @author sekobey
 *
 */
public class Parameters {
	private static final String BUNDLE_NAME = "jcataloger.resources.parameters"; //$NON-NLS-1$

	private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
			.getBundle(BUNDLE_NAME);

	private Parameters() {
	}

	public static String getString(String key) {
		try {
			return RESOURCE_BUNDLE.getString(key);
		} catch (MissingResourceException e) {
			return '!' + key + '!';
		}
	}
}
